// https://reactnavigation.org/docs/stack-navigator/#animationtypeforreplace
// import {CardStyleInterpolators} from '@react-navigation/native-stack'
export default function customNavComponent(props, screen, navTitle) {
  console.log('cusNav--props=', props)
  let config = {}
  // config.cardStyleInterpolator = CardStyleInterpolators.forHorizontalIOS
  if (
    screen &&
    screen.navigationOptions &&
    typeof screen.navigationOptions === 'function'
  ) {
    /**
     * 我们可以自定义 导航栏
     * 1、自定义标题、左侧、右侧
     * 2、自定义 整体的导航栏
     */
    config = screen.navigationOptions(config, props)
  } else if (navTitle) {
    config.headerTitle = navTitle || ''
  }
  return config
}
// https://reactnavigation.org/docs/custom-navigators
